package com.new1cloud.file.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Component
@ConfigurationProperties(prefix = "upload")
public class UploadConfig {

    /**
     * 上传的临时目录
     */
    private static String temPath;
    /**
     * 分片大小，单位字节
     */
    private static Long chunkSize;
    /**
     * 文件上传服务端通信端口
     */
    private static Integer serverPort;

    public static String getTemPath() {
        return temPath;
    }
    public void setTemPath(String temPath) {
        UploadConfig.temPath = temPath;
    }
    public static Long getChunkSize() {
        return chunkSize;
    }
    public void setChunkSize(Long chunkSize) {
        UploadConfig.chunkSize = chunkSize;
    }

    public static Integer getServerPort() {
        return serverPort;
    }

    public void setServerPort(Integer serverPort) {
        UploadConfig.serverPort = serverPort;
    }
}
